#returts the pdf value for sample x over the set of given samples
#x - sample to classify (1 row of relevant attributes' values)
#samples - samples constituing a class (collection of rows of relevant attributes' values)
#width - width of the Parzen window to use
#
function p = parzen(x,samples,width)
p=0;
h=width/sqrt(size(samples,1));

    for i=1:size(samples,1)
        p+=1/h*window(distance(x,samples(i,:))/h);
    end;
    p/=size(samples,1);
end
